<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:v="urn:schemas-microsoft-com:vml">
<head>
    <meta http-equiv="content-type" content="text/html; charset=UTF-8"/>
    <title>Google Maps</title>
    <script src="http://maps.google.com/maps?file=api&amp;v=2&amp;key=ABQIAAAAq5WrhBdJUM8mEWczM0pZUBQKq9tVB4bxY80mU6IbIc8nv2K8uxTuPZfH8aQwU2cVqExByeYvMZP9lg" type="text/javascript"></script>

<script type="text/javascript">
function MyFn(){
	map.removeOverlay(insert2);}
	var insert2 = new EInsert(new GLatLng(-34.928615, 138.599981), "http://bender/~sk2/olsr/topology.png", new GSize( <? echo ($size[0]); ?>,  <?echo($size[1]);?>), 17);
map.addOverlay(insert2);
}

function running()
{
	//runs periodically
	timerID = setInterval("MyFn()",10000)
}


</script>

</head>

<body onLoad="running()" onunload="GUnload()">

    <h1>YO!</h1>
        
    <div id="map" style="width: 768px; height: 512px"></div>

<?
$filename = "http://bender/~sk2/olsr/topology.png";
$size = getimagesize($filename);
?>

    <noscript><b>JavaScript must be enabled in order for you to use Google Maps.</b> 
      However, it seems JavaScript is either disabled or not supported by your browser. 
      To view Google Maps, enable JavaScript by changing your browser options, and then 
      try again.
    </noscript>
 
    <script src="einsert.js" type="text/javascript"></script>

    <script type="text/javascript">


    //<![CDATA[
    
    if (GBrowserIsCompatible()) { 

      var map = new GMap2(document.getElementById("map"));
      map.addControl(new GLargeMapControl());
      map.addControl(new GMapTypeControl());
      map.setCenter(new GLatLng(-34.928615, 138.599981),17);
	  
	  // Insert the Test image 
      var insert2 = new EInsert(new GLatLng(-34.928615, 138.599981), "http://bender/~sk2/olsr/topology.png", new GSize( <? echo ($size[0]); ?>,  <?echo($size[1]);?>), 17);
      map.addOverlay(insert2);
      
    }
    
    else {
      alert("Sorry, the Google Maps API is not compatible with this browser");
    }

    // This Javascript is based on code provided by the
    // Blackpool Community Church Javascript Team
    // http://www.commchurch.freeserve.co.uk/   
    // http://www.econym.demon.co.uk/googlemaps/

    //]]>
    </script>
  </body>

</html>



